package com.zxp.springcloud.service;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @description:
 * @author: 张新朋
 * @time: 2020/5/6 14:05
 */
@Component
@FeignClient(value = "CLOUD-PROVIDER-HYSTRIX-PAYMENT",fallback = PaymentFallBackService.class)
public interface PaymentHystrixService {

    @GetMapping("/paymemt/hystrix/ok/{id}")
    public String get_OK(@PathVariable("id") Integer id);

    @GetMapping("/paymemt/hystrix/error/{id}")
    public String get_ERROR(@PathVariable("id") Integer id);
}